<!DOCTYPE html>
<html lang="" xml:lang="">
<head>

  <meta charset="utf-8" />
  <meta http-equiv="X-UA-Compatible" content="IE=edge" />
  <title>1 Maple | 编程语言笔记</title>
  <meta name="description" content="1 Maple | 编程语言笔记" />
  <meta name="generator" content="bookdown 0.35 and GitBook 2.6.7" />

  <meta property="og:title" content="1 Maple | 编程语言笔记" />
  <meta property="og:type" content="book" />
  
  
  

  <meta name="twitter:card" content="summary" />
  <meta name="twitter:title" content="1 Maple | 编程语言笔记" />
  
  
  

<meta name="author" content="云腾足下" />



  <meta name="viewport" content="width=device-width, initial-scale=1" />
  <meta name="apple-mobile-web-app-capable" content="yes" />
  <meta name="apple-mobile-web-app-status-bar-style" content="black" />
  
  
<link rel="prev" href="index.html"/>
<link rel="next" href="Julia.html"/>
<script src="libs/jquery-3.6.0/jquery-3.6.0.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/fuse.js@6.4.6/dist/fuse.min.js"></script>
<link href="libs/gitbook-2.6.7/css/style.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-table.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-bookdown.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-highlight.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-search.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-fontsettings.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-clipboard.css" rel="stylesheet" />








<link href="libs/anchor-sections-1.1.0/anchor-sections.css" rel="stylesheet" />
<link href="libs/anchor-sections-1.1.0/anchor-sections-hash.css" rel="stylesheet" />
<script src="libs/anchor-sections-1.1.0/anchor-sections.js"></script>
<script type="text/x-mathjax-config">
MathJax.Hub.Config({
  jax: ["input/TeX","output/SVG"],
  extensions: ["tex2jax.js","MathMenu.js","MathZoom.js"],
  TeX: {
    extensions: ["AMSmath.js","AMSsymbols.js","noErrors.js","noUndefined.js"]
  }
});
</script>
<script type="text/javascript"
   src="../../../MathJax/MathJax.js">
</script>


<style type="text/css">
pre > code.sourceCode { white-space: pre; position: relative; }
pre > code.sourceCode > span { display: inline-block; line-height: 1.25; }
pre > code.sourceCode > span:empty { height: 1.2em; }
.sourceCode { overflow: visible; }
code.sourceCode > span { color: inherit; text-decoration: inherit; }
pre.sourceCode { margin: 0; }
@media screen {
div.sourceCode { overflow: auto; }
}
@media print {
pre > code.sourceCode { white-space: pre-wrap; }
pre > code.sourceCode > span { text-indent: -5em; padding-left: 5em; }
}
pre.numberSource code
  { counter-reset: source-line 0; }
pre.numberSource code > span
  { position: relative; left: -4em; counter-increment: source-line; }
pre.numberSource code > span > a:first-child::before
  { content: counter(source-line);
    position: relative; left: -1em; text-align: right; vertical-align: baseline;
    border: none; display: inline-block;
    -webkit-touch-callout: none; -webkit-user-select: none;
    -khtml-user-select: none; -moz-user-select: none;
    -ms-user-select: none; user-select: none;
    padding: 0 4px; width: 4em;
    color: #aaaaaa;
  }
pre.numberSource { margin-left: 3em; border-left: 1px solid #aaaaaa;  padding-left: 4px; }
div.sourceCode
  {   }
@media screen {
pre > code.sourceCode > span > a:first-child::before { text-decoration: underline; }
}
code span.al { color: #ff0000; font-weight: bold; } /* Alert */
code span.an { color: #60a0b0; font-weight: bold; font-style: italic; } /* Annotation */
code span.at { color: #7d9029; } /* Attribute */
code span.bn { color: #40a070; } /* BaseN */
code span.bu { color: #008000; } /* BuiltIn */
code span.cf { color: #007020; font-weight: bold; } /* ControlFlow */
code span.ch { color: #4070a0; } /* Char */
code span.cn { color: #880000; } /* Constant */
code span.co { color: #60a0b0; font-style: italic; } /* Comment */
code span.cv { color: #60a0b0; font-weight: bold; font-style: italic; } /* CommentVar */
code span.do { color: #ba2121; font-style: italic; } /* Documentation */
code span.dt { color: #902000; } /* DataType */
code span.dv { color: #40a070; } /* DecVal */
code span.er { color: #ff0000; font-weight: bold; } /* Error */
code span.ex { } /* Extension */
code span.fl { color: #40a070; } /* Float */
code span.fu { color: #06287e; } /* Function */
code span.im { color: #008000; font-weight: bold; } /* Import */
code span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Information */
code span.kw { color: #007020; font-weight: bold; } /* Keyword */
code span.op { color: #666666; } /* Operator */
code span.ot { color: #007020; } /* Other */
code span.pp { color: #bc7a00; } /* Preprocessor */
code span.sc { color: #4070a0; } /* SpecialChar */
code span.ss { color: #bb6688; } /* SpecialString */
code span.st { color: #4070a0; } /* String */
code span.va { color: #19177c; } /* Variable */
code span.vs { color: #4070a0; } /* VerbatimString */
code span.wa { color: #60a0b0; font-weight: bold; font-style: italic; } /* Warning */
</style>

<style type="text/css">
  
  div.hanging-indent{margin-left: 1.5em; text-indent: -1.5em;}
</style>

</head>

<body>



  <div class="book without-animation with-summary font-size-2 font-family-1" data-basepath=".">

    <div class="book-summary">
      <nav role="navigation">

<ul class="summary">
<li class="chapter" data-level="" data-path="index.html"><a href="index.html"><i class="fa fa-check"></i>序</a></li>
<li class="chapter" data-level="1" data-path="Maple.html"><a href="Maple.html"><i class="fa fa-check"></i><b>1</b> Maple</a>
<ul>
<li class="chapter" data-level="1.1" data-path="Maple.html"><a href="Maple.html#快捷键"><i class="fa fa-check"></i><b>1.1</b> 快捷键</a></li>
<li class="chapter" data-level="1.2" data-path="Maple.html"><a href="Maple.html#几个基本的代数处理"><i class="fa fa-check"></i><b>1.2</b> 几个基本的代数处理</a></li>
<li class="chapter" data-level="1.3" data-path="Maple.html"><a href="Maple.html#产生序列"><i class="fa fa-check"></i><b>1.3</b> 产生序列</a></li>
<li class="chapter" data-level="1.4" data-path="Maple.html"><a href="Maple.html#函数定义"><i class="fa fa-check"></i><b>1.4</b> 函数定义</a>
<ul>
<li class="chapter" data-level="1.4.1" data-path="Maple.html"><a href="Maple.html#参数的宣称"><i class="fa fa-check"></i><b>1.4.1</b> 参数的宣称</a></li>
</ul></li>
<li class="chapter" data-level="1.5" data-path="Maple.html"><a href="Maple.html#控制流"><i class="fa fa-check"></i><b>1.5</b> 控制流</a></li>
<li class="chapter" data-level="1.6" data-path="Maple.html"><a href="Maple.html#画图"><i class="fa fa-check"></i><b>1.6</b> 画图</a></li>
<li class="chapter" data-level="1.7" data-path="Maple.html"><a href="Maple.html#矩阵"><i class="fa fa-check"></i><b>1.7</b> 矩阵</a></li>
<li class="chapter" data-level="1.8" data-path="Maple.html"><a href="Maple.html#一句话tips"><i class="fa fa-check"></i><b>1.8</b> 一句话Tips</a></li>
</ul></li>
<li class="chapter" data-level="2" data-path="Julia.html"><a href="Julia.html"><i class="fa fa-check"></i><b>2</b> Julia</a>
<ul>
<li class="chapter" data-level="2.1" data-path="Julia.html"><a href="Julia.html#julia的一些体会"><i class="fa fa-check"></i><b>2.1</b> Julia的一些体会</a>
<ul>
<li class="chapter" data-level="2.1.1" data-path="Julia.html"><a href="Julia.html#关于函数的参数"><i class="fa fa-check"></i><b>2.1.1</b> 关于函数的参数</a></li>
</ul></li>
<li class="chapter" data-level="2.2" data-path="Julia.html"><a href="Julia.html#julia的一些常用包"><i class="fa fa-check"></i><b>2.2</b> Julia的一些常用包</a>
<ul>
<li class="chapter" data-level="2.2.1" data-path="Julia.html"><a href="Julia.html#优化包"><i class="fa fa-check"></i><b>2.2.1</b> 优化包</a></li>
<li class="chapter" data-level="2.2.2" data-path="Julia.html"><a href="Julia.html#julia数值求根"><i class="fa fa-check"></i><b>2.2.2</b> Julia数值求根</a></li>
<li class="chapter" data-level="2.2.3" data-path="Julia.html"><a href="Julia.html#dataframes包"><i class="fa fa-check"></i><b>2.2.3</b> <code>DataFrames</code>包</a></li>
</ul></li>
<li class="chapter" data-level="2.3" data-path="Julia.html"><a href="Julia.html#julia的ide体验"><i class="fa fa-check"></i><b>2.3</b> Julia的IDE体验</a></li>
<li class="chapter" data-level="2.4" data-path="Julia.html"><a href="Julia.html#其他tips"><i class="fa fa-check"></i><b>2.4</b> 其他tips</a></li>
</ul></li>
<li class="chapter" data-level="3" data-path="Stata.html"><a href="Stata.html"><i class="fa fa-check"></i><b>3</b> Stata</a>
<ul>
<li class="chapter" data-level="3.1" data-path="Stata.html"><a href="Stata.html#数据处理"><i class="fa fa-check"></i><b>3.1</b> 数据处理</a></li>
<li class="chapter" data-level="3.2" data-path="Stata.html"><a href="Stata.html#回归相关"><i class="fa fa-check"></i><b>3.2</b> 回归相关</a>
<ul>
<li class="chapter" data-level="3.2.1" data-path="Stata.html"><a href="Stata.html#描述性统计和回归结果导出"><i class="fa fa-check"></i><b>3.2.1</b> 描述性统计和回归结果导出</a></li>
</ul></li>
<li class="chapter" data-level="3.3" data-path="Stata.html"><a href="Stata.html#一些外部命令"><i class="fa fa-check"></i><b>3.3</b> 一些外部命令</a></li>
<li class="chapter" data-level="3.4" data-path="Stata.html"><a href="Stata.html#stata对某个变量随机抽样"><i class="fa fa-check"></i><b>3.4</b> stata对某个变量随机抽样</a></li>
<li class="chapter" data-level="3.5" data-path="Stata.html"><a href="Stata.html#stata调用r"><i class="fa fa-check"></i><b>3.5</b> Stata调用R</a></li>
<li class="chapter" data-level="3.6" data-path="Stata.html"><a href="Stata.html#miscellaneous"><i class="fa fa-check"></i><b>3.6</b> Miscellaneous</a></li>
</ul></li>
<li class="chapter" data-level="4" data-path="Matlab.html"><a href="Matlab.html"><i class="fa fa-check"></i><b>4</b> Matlab</a>
<ul>
<li class="chapter" data-level="4.1" data-path="Matlab.html"><a href="Matlab.html#一句话tips-1"><i class="fa fa-check"></i><b>4.1</b> 一句话Tips</a></li>
<li class="chapter" data-level="4.2" data-path="Matlab.html"><a href="Matlab.html#带名称和缺省值的参数设置"><i class="fa fa-check"></i><b>4.2</b> 带名称和缺省值的参数设置</a></li>
<li class="chapter" data-level="4.3" data-path="Matlab.html"><a href="Matlab.html#窗口输出到文本"><i class="fa fa-check"></i><b>4.3</b> 窗口输出到文本</a></li>
<li class="chapter" data-level="4.4" data-path="Matlab.html"><a href="Matlab.html#gvar-toolbox使用报告"><i class="fa fa-check"></i><b>4.4</b> GVAR Toolbox使用报告</a>
<ul>
<li class="chapter" data-level="4.4.1" data-path="Matlab.html"><a href="Matlab.html#数据输入"><i class="fa fa-check"></i><b>4.4.1</b> 数据输入</a></li>
<li class="chapter" data-level="4.4.2" data-path="Matlab.html"><a href="Matlab.html#模型设定"><i class="fa fa-check"></i><b>4.4.2</b> 模型设定</a></li>
<li class="chapter" data-level="4.4.3" data-path="Matlab.html"><a href="Matlab.html#一些坑"><i class="fa fa-check"></i><b>4.4.3</b> 一些坑</a></li>
</ul></li>
</ul></li>
<li class="chapter" data-level="5" data-path="git操作流程.html"><a href="git操作流程.html"><i class="fa fa-check"></i><b>5</b> git操作流程</a>
<ul>
<li class="chapter" data-level="5.1" data-path="git操作流程.html"><a href="git操作流程.html#基本语法"><i class="fa fa-check"></i><b>5.1</b> 基本语法</a></li>
<li class="chapter" data-level="5.2" data-path="git操作流程.html"><a href="git操作流程.html#生成公钥"><i class="fa fa-check"></i><b>5.2</b> 生成公钥</a></li>
<li class="chapter" data-level="5.3" data-path="git操作流程.html"><a href="git操作流程.html#本地库操作"><i class="fa fa-check"></i><b>5.3</b> 本地库操作</a></li>
<li class="chapter" data-level="5.4" data-path="git操作流程.html"><a href="git操作流程.html#关联远程库码云"><i class="fa fa-check"></i><b>5.4</b> 关联远程库（码云）</a></li>
<li class="chapter" data-level="5.5" data-path="git操作流程.html"><a href="git操作流程.html#打开vi后的操作"><i class="fa fa-check"></i><b>5.5</b> 打开VI后的操作</a></li>
<li class="chapter" data-level="5.6" data-path="git操作流程.html"><a href="git操作流程.html#给递交进行标记"><i class="fa fa-check"></i><b>5.6</b> 给递交进行标记</a></li>
</ul></li>
<li class="chapter" data-level="6" data-path="C.html"><a href="C.html"><i class="fa fa-check"></i><b>6</b> C语言</a>
<ul>
<li class="chapter" data-level="6.1" data-path="C.html"><a href="C.html#一句话tips-2"><i class="fa fa-check"></i><b>6.1</b> 一句话Tips</a></li>
</ul></li>
<li class="chapter" data-level="7" data-path="Latex.html"><a href="Latex.html"><i class="fa fa-check"></i><b>7</b> Latex</a>
<ul>
<li class="chapter" data-level="7.1" data-path="Latex.html"><a href="Latex.html#一句话tips-3"><i class="fa fa-check"></i><b>7.1</b> 一句话Tips</a></li>
<li class="chapter" data-level="7.2" data-path="Latex.html"><a href="Latex.html#使用pdfpages包插入pdf页面"><i class="fa fa-check"></i><b>7.2</b> 使用<code>pdfpages</code>包插入PDF页面</a></li>
<li class="chapter" data-level="7.3" data-path="Latex.html"><a href="Latex.html#记录几个快捷键"><i class="fa fa-check"></i><b>7.3</b> 记录几个快捷键</a></li>
<li class="chapter" data-level="7.4" data-path="Latex.html"><a href="Latex.html#手动安装新的宏包"><i class="fa fa-check"></i><b>7.4</b> 手动安装新的宏包</a></li>
<li class="chapter" data-level="7.5" data-path="Latex.html"><a href="Latex.html#beamer相关"><i class="fa fa-check"></i><b>7.5</b> <code>beamer</code>相关</a></li>
<li class="chapter" data-level="7.6" data-path="Latex.html"><a href="Latex.html#表格相关"><i class="fa fa-check"></i><b>7.6</b> 表格相关</a>
<ul>
<li class="chapter" data-level="7.6.1" data-path="Latex.html"><a href="Latex.html#长表格"><i class="fa fa-check"></i><b>7.6.1</b> 长表格</a></li>
</ul></li>
<li class="chapter" data-level="7.7" data-path="Latex.html"><a href="Latex.html#章节标题格式修改"><i class="fa fa-check"></i><b>7.7</b> 章节标题格式修改</a></li>
<li class="chapter" data-level="7.8" data-path="Latex.html"><a href="Latex.html#数学公式相关"><i class="fa fa-check"></i><b>7.8</b> 数学公式相关</a>
<ul>
<li class="chapter" data-level="7.8.1" data-path="Latex.html"><a href="Latex.html#数学公式左对齐"><i class="fa fa-check"></i><b>7.8.1</b> 数学公式左对齐</a></li>
</ul></li>
<li class="chapter" data-level="7.9" data-path="Latex.html"><a href="Latex.html#中文字体加粗"><i class="fa fa-check"></i><b>7.9</b> 中文字体加粗</a></li>
<li class="chapter" data-level="7.10" data-path="Latex.html"><a href="Latex.html#使用某种常用字体"><i class="fa fa-check"></i><b>7.10</b> 使用某种常用字体</a>
<ul>
<li class="chapter" data-level="7.10.1" data-path="Latex.html"><a href="Latex.html#如何使用一个新的字体"><i class="fa fa-check"></i><b>7.10.1</b> 如何使用一个新的字体？</a></li>
</ul></li>
<li class="chapter" data-level="7.11" data-path="Latex.html"><a href="Latex.html#我的r代码排版模版"><i class="fa fa-check"></i><b>7.11</b> 我的R代码排版模版</a>
<ul>
<li class="chapter" data-level="7.11.1" data-path="Latex.html"><a href="Latex.html#listings包"><i class="fa fa-check"></i><b>7.11.1</b> <code>listings</code>包</a></li>
<li class="chapter" data-level="7.11.2" data-path="Latex.html"><a href="Latex.html#fancyvrb包"><i class="fa fa-check"></i><b>7.11.2</b> <code>fancyvrb</code>包</a></li>
</ul></li>
<li class="chapter" data-level="7.12" data-path="Latex.html"><a href="Latex.html#latex插入附录"><i class="fa fa-check"></i><b>7.12</b> latex插入附录</a></li>
<li class="chapter" data-level="7.13" data-path="Latex.html"><a href="Latex.html#latex参考文献的编码思路"><i class="fa fa-check"></i><b>7.13</b> latex参考文献的编码思路</a>
<ul>
<li class="chapter" data-level="7.13.1" data-path="Latex.html"><a href="Latex.html#参考文献较少的情况"><i class="fa fa-check"></i><b>7.13.1</b> 参考文献较少的情况</a></li>
<li class="chapter" data-level="7.13.2" data-path="Latex.html"><a href="Latex.html#参考文献较多的情况"><i class="fa fa-check"></i><b>7.13.2</b> 参考文献较多的情况</a></li>
<li class="chapter" data-level="7.13.3" data-path="Latex.html"><a href="Latex.html#如何将文献引用作为上标出现"><i class="fa fa-check"></i><b>7.13.3</b> 如何将文献引用作为上标出现？</a></li>
</ul></li>
<li class="chapter" data-level="7.14" data-path="Latex.html"><a href="Latex.html#一些文体的模版"><i class="fa fa-check"></i><b>7.14</b> 一些文体的模版</a>
<ul>
<li class="chapter" data-level="7.14.1" data-path="Latex.html"><a href="Latex.html#社科申报课题部分模版"><i class="fa fa-check"></i><b>7.14.1</b> 社科申报课题部分模版</a></li>
</ul></li>
</ul></li>
<li class="chapter" data-level="8" data-path="Blog.html"><a href="Blog.html"><i class="fa fa-check"></i><b>8</b> 博客</a></li>
<li class="chapter" data-level="9" data-path="OS.html"><a href="OS.html"><i class="fa fa-check"></i><b>9</b> macOS操作系统</a>
<ul>
<li class="chapter" data-level="9.1" data-path="OS.html"><a href="OS.html#一句话tips-4"><i class="fa fa-check"></i><b>9.1</b> 一句话Tips</a></li>
<li class="chapter" data-level="9.2" data-path="OS.html"><a href="OS.html#安装和配置latex"><i class="fa fa-check"></i><b>9.2</b> 安装和配置Latex</a></li>
<li class="chapter" data-level="9.3" data-path="OS.html"><a href="OS.html#homebrew"><i class="fa fa-check"></i><b>9.3</b> Homebrew</a></li>
<li class="chapter" data-level="9.4" data-path="OS.html"><a href="OS.html#挂载外置磁盘"><i class="fa fa-check"></i><b>9.4</b> 挂载外置磁盘</a></li>
</ul></li>
<li class="chapter" data-level="10" data-path="Mathematica.html"><a href="Mathematica.html"><i class="fa fa-check"></i><b>10</b> Mathematica</a>
<ul>
<li class="chapter" data-level="10.1" data-path="Mathematica.html"><a href="Mathematica.html#快捷键-1"><i class="fa fa-check"></i><b>10.1</b> 快捷键</a></li>
</ul></li>
<li class="chapter" data-level="11" data-path="Python.html"><a href="Python.html"><i class="fa fa-check"></i><b>11</b> python</a>
<ul>
<li class="chapter" data-level="11.1" data-path="Python.html"><a href="Python.html#vscode下配置python"><i class="fa fa-check"></i><b>11.1</b> VSCode下配置python</a></li>
</ul></li>
<li class="chapter" data-level="12" data-path="Other.html"><a href="Other.html"><i class="fa fa-check"></i><b>12</b> 其他小众软件</a>
<ul>
<li class="chapter" data-level="12.1" data-path="Other.html"><a href="Other.html#pdf文件压缩"><i class="fa fa-check"></i><b>12.1</b> PDF文件压缩</a></li>
<li class="chapter" data-level="12.2" data-path="Other.html"><a href="Other.html#eviews编程"><i class="fa fa-check"></i><b>12.2</b> Eviews编程</a></li>
<li class="chapter" data-level="12.3" data-path="Other.html"><a href="Other.html#gauss"><i class="fa fa-check"></i><b>12.3</b> GAUSS</a>
<ul>
<li class="chapter" data-level="12.3.1" data-path="Other.html"><a href="Other.html#系统函数"><i class="fa fa-check"></i><b>12.3.1</b> 系统函数</a></li>
</ul></li>
<li class="chapter" data-level="12.4" data-path="Other.html"><a href="Other.html#zotero"><i class="fa fa-check"></i><b>12.4</b> Zotero</a></li>
<li class="chapter" data-level="12.5" data-path="Other.html"><a href="Other.html#word中插入公式"><i class="fa fa-check"></i><b>12.5</b> Word中插入公式</a>
<ul>
<li class="chapter" data-level="12.5.1" data-path="Other.html"><a href="Other.html#自带的公式输入"><i class="fa fa-check"></i><b>12.5.1</b> 自带的公式输入</a></li>
<li class="chapter" data-level="12.5.2" data-path="Other.html"><a href="Other.html#公式编号的其他方法"><i class="fa fa-check"></i><b>12.5.2</b> 公式编号的其他方法</a></li>
<li class="chapter" data-level="12.5.3" data-path="Other.html"><a href="Other.html#利用texsword编辑器"><i class="fa fa-check"></i><b>12.5.3</b> 利用TexsWord编辑器</a></li>
</ul></li>
<li class="chapter" data-level="12.6" data-path="Other.html"><a href="Other.html#noteexpress样式设置"><i class="fa fa-check"></i><b>12.6</b> NoteExpress样式设置</a></li>
<li class="chapter" data-level="12.7" data-path="Other.html"><a href="Other.html#filezilla"><i class="fa fa-check"></i><b>12.7</b> FileZilla</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="references.html"><a href="references.html"><i class="fa fa-check"></i>References</a></li>
</ul>

      </nav>
    </div>

    <div class="book-body">
      <div class="body-inner">
        <div class="book-header" role="navigation">
          <h1>
            <i class="fa fa-circle-o-notch fa-spin"></i><a href="./">编程语言笔记</a>
          </h1>
        </div>

        <div class="page-wrapper" tabindex="-1" role="main">
          <div class="page-inner">

            <section class="normal" id="section-">
<div id="Maple" class="section level1 hasAnchor" number="1">
<h1><span class="header-section-number">1</span> Maple<a href="Maple.html#Maple" class="anchor-section" aria-label="Anchor link to header"></a></h1>
<div id="快捷键" class="section level2 hasAnchor" number="1.1">
<h2><span class="header-section-number">1.1</span> 快捷键<a href="Maple.html#快捷键" class="anchor-section" aria-label="Anchor link to header"></a></h2>
<ul>
<li><code>ctrl+del</code>删除全行</li>
<li><code>ctrl+K,ctrl+J</code>在前或后插入一行</li>
<li><code>?plot</code>看帮助</li>
<li><code>with(plottools)</code>载入包</li>
<li><code>F5</code>文本和数学之间切换，<code>shift+F5</code>，可执行的公式和不可执行的公式之间切换。</li>
</ul>
</div>
<div id="几个基本的代数处理" class="section level2 hasAnchor" number="1.2">
<h2><span class="header-section-number">1.2</span> 几个基本的代数处理<a href="Maple.html#几个基本的代数处理" class="anchor-section" aria-label="Anchor link to header"></a></h2>
<!-- 通常`simplify,combine,expand,convert`进行化简 -->
<ul>
<li>复合函数<span class="math inline">\(f(g(x))\)</span>可以写成，<code>(evalf@arccos)(2/3)</code>，这就对反余弦进行了数值评价</li>
<li><code>factor,expand,simplify，collect</code>会进行因式分解，多项式展开，化简，合并同类项。带有附加关系的化简,<code>simplify(expr, {x*z=1})</code></li>
</ul>
</div>
<div id="产生序列" class="section level2 hasAnchor" number="1.3">
<h2><span class="header-section-number">1.3</span> 产生序列<a href="Maple.html#产生序列" class="anchor-section" aria-label="Anchor link to header"></a></h2>
<p>中括号产生list，它是有序的。大括号产生集合，它是无序的。下面的代码可以产生一系列值。</p>
<pre><code>L:= [a1,a2,a3]:
map(f, L)
# [f(a1),f(a2),f(a3)]</code></pre>
<p>可以使用<code>L[i..j]</code>来选择集合中的元素，也可以使用<code>op(i..j,L)</code>来选择多个元素。当然，使用<code>seq</code>函数也能产生一系列值。</p>
<pre><code>[seq(f(n),n=n1..n2)]</code></pre>
</div>
<div id="函数定义" class="section level2 hasAnchor" number="1.4">
<h2><span class="header-section-number">1.4</span> 函数定义<a href="Maple.html#函数定义" class="anchor-section" aria-label="Anchor link to header"></a></h2>
<ul>
<li>简单函数定义：<code>f:=x-&gt;(1+x)^(1/x)</code></li>
<li>复杂函数定义：</li>
</ul>
<pre><code>f:=proc(x)
(1+x)^(1/x)
end proc:</code></pre>
<div id="参数的宣称" class="section level3 hasAnchor" number="1.4.1">
<h3><span class="header-section-number">1.4.1</span> 参数的宣称<a href="Maple.html#参数的宣称" class="anchor-section" aria-label="Anchor link to header"></a></h3>
<ul>
<li>如下写法可以按位置给参数赋值</li>
</ul>
<pre><code>f := proc(a::integer := 10, b::expects(integer) := 100.1) a + b end proc:</code></pre>
<ul>
<li>也可以按参数名称赋值，但写法略有不同</li>
</ul>
<pre><code>f := proc( { simple::integer := 2 } )
    sprintf(&quot;simple=%d&quot;,simple)
end proc:</code></pre>
</div>
</div>
<div id="控制流" class="section level2 hasAnchor" number="1.5">
<h2><span class="header-section-number">1.5</span> 控制流<a href="Maple.html#控制流" class="anchor-section" aria-label="Anchor link to header"></a></h2>
<ul>
<li>条件语句：</li>
</ul>
<pre><code>if ...then...
elif...then...
else ... 
end if:</code></pre>
</div>
<div id="画图" class="section level2 hasAnchor" number="1.6">
<h2><span class="header-section-number">1.6</span> 画图<a href="Maple.html#画图" class="anchor-section" aria-label="Anchor link to header"></a></h2>
<ul>
<li>2D图：<code>plot(sin(x), x=-Pi..2*Pi);</code></li>
<li>3D图：<code>plot3d(f(x,y),x=a..b,y=c..d)</code></li>
<li>等高线图：<code>plots[contourplot](f(x,y),x=a..b,y=c..d)</code></li>
<li>多图叠在一张图显示：<code>plots[display](p1,p2,p3)</code></li>
</ul>
</div>
<div id="矩阵" class="section level2 hasAnchor" number="1.7">
<h2><span class="header-section-number">1.7</span> 矩阵<a href="Maple.html#矩阵" class="anchor-section" aria-label="Anchor link to header"></a></h2>
<ul>
<li>通常要载入包<code>LinearAlgebra</code>和<code>linalg</code>。</li>
<li>产生脚标为<span class="math inline">\(a_{i,j}\)</span>的矩阵<span class="math inline">\(A\)</span>。</li>
</ul>
<pre><code>A:=array([a[1,1],a[1,2]],[a[2,1], a[2,2]])
A:=Matrix([a[1,1],a[1,2]],[a[2,1], a[2,2]])
A:=Matrix(2,2,symbol = a)
A:=Vector(2, symbol = a)</code></pre>
<ul>
<li>矩阵计算</li>
</ul>
<pre><code>with(LinearAlgebra):
evalm(A^2)
A.B # 矩阵相乘</code></pre>
</div>
<div id="一句话tips" class="section level2 hasAnchor" number="1.8">
<h2><span class="header-section-number">1.8</span> 一句话Tips<a href="Maple.html#一句话tips" class="anchor-section" aria-label="Anchor link to header"></a></h2>
<ul>
<li><code>#</code> 是注释。</li>
<li>对于<span class="math inline">\(\left(-\frac{3}{4}\right)^{2/3}\)</span>Maple不会主动化简，因为它不知道这个指数的底是正还是负。此时可以使用<code>surd(x,n)</code>函数
<span class="math display">\[surd(x,n)=\begin{cases}x^{1/n},x\ge 0\\ -(-x)^{1/n},x&lt;0\end{cases}\]</span></li>
</ul>
<p>命令如<code>surd((-3/4)^(2/3),3)^2</code></p>
<ul>
<li>语句可以清除原来的<code>f</code>的定义，</li>
<li>多项式降幂排列<code>sort(x^3*y-y^3*x,[y,x])</code></li>
<li>乘号记得输入<code>*</code>，各种数学运算：</li>
<li>求导：<code>diff(f,x)</code>; 求二阶导数，<code>diff(f,x$2)</code></li>
<li><code>nops</code>返回比如向量的元素的数目：</li>
</ul>
<pre><code>u:=[1,4,9]:
nops(u);</code></pre>
<ul>
<li>求具体的数值，用<code>evalf(Pi)</code></li>
<li>矩阵相乘用<code>.</code></li>
<li>它的<code>surfdata</code>以点的数值的形式绘制三维曲线，相对比较好看。</li>
<li>用<code>y</code>替换表达式中的<code>x</code>：<code>subs(x=y, expression)</code></li>
</ul>

</div>
</div>
            </section>

          </div>
        </div>
      </div>
<a href="index.html" class="navigation navigation-prev " aria-label="Previous page"><i class="fa fa-angle-left"></i></a>
<a href="Julia.html" class="navigation navigation-next " aria-label="Next page"><i class="fa fa-angle-right"></i></a>
    </div>
  </div>
<script src="libs/gitbook-2.6.7/js/app.min.js"></script>
<script src="libs/gitbook-2.6.7/js/clipboard.min.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-search.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-sharing.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-fontsettings.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-bookdown.js"></script>
<script src="libs/gitbook-2.6.7/js/jquery.highlight.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-clipboard.js"></script>
<script>
gitbook.require(["gitbook"], function(gitbook) {
gitbook.start({
"sharing": {
"github": false,
"facebook": true,
"twitter": true,
"linkedin": false,
"weibo": false,
"instapaper": false,
"vk": false,
"whatsapp": false,
"all": ["facebook", "twitter", "linkedin", "weibo", "instapaper"]
},
"fontsettings": {
"theme": "white",
"family": "sans",
"size": 2
},
"edit": {
"link": null,
"text": null
},
"history": {
"link": null,
"text": null
},
"view": {
"link": null,
"text": null
},
"download": ["CBook.pdf"],
"search": {
"engine": "fuse",
"options": null
},
"toc": {
"collapse": "subsection"
}
});
});
</script>

<!-- dynamically load mathjax for compatibility with self-contained -->
<script>
  (function () {
    var script = document.createElement("script");
    script.type = "text/javascript";
    var src = "true";
    if (src === "" || src === "true") src = "https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.9/latest.js?config=TeX-MML-AM_CHTML";
    if (location.protocol !== "file:")
      if (/^https?:/.test(src))
        src = src.replace(/^https?:/, '');
    script.src = src;
    document.getElementsByTagName("head")[0].appendChild(script);
  })();
</script>
</body>

</html>
